Method for training a driving related object detector

ABSTRACT

A method for driving-related object detection, the method may include receiving an input image by an input of an object detector; and detecting, by an object detector, objects that appear in the input image. The detecting includes searching for (i) a first object having a first size that is within a first size range and belongs to a four wheel vehicle class, (ii) a second object having a second size that is within a second size range and belongs to a subclass out of multiple four wheel vehicle subclasses, (iii) a pedestrian, and (iv) a two wheel vehicle; wherein a maximum of the first size range does not substantially exceed a minimum of the second size range.

BACKGROUND

Object detection is required in various systems and applications.

Autonomous vehicles and advanced driver assistance systems (ADAS) mayinclude object detection units that should detect driving relatedobjects such as vehicles and pedestrians.

These object detection units are trained using a supervised machinelearning process.

In a supervised machine learning process test images are fed to anobject detector that outputs an estimate of the objects that appear inthe test images.

An error unit receives the estimate and calculated an error between theestimate and reference information that indicates which objects appearedin the test images.

The error is fed to the object detector in order to adjust the objectdetector to the actual objects that appeared in the test images.

The error calculation and the adjustment of the object detector may beperformed in an iterative manner—for example per test image.

The reference information may be generated manually or by other errorprone processes and this may reduce the accuracy of the errorcalculation.

Furthermore—the object detector may be adjusted to compensate forinsignificant differences between objects. This adjustment may deviatethe configuration of the object detector from an ideal configuration andmay also consume many computational resources.

There is a growing need to provide a method, computer readable mediumand a system that may be able to provide highly accurate objectdetection at a low cost.

SUMMARY

There may be provided a method for driving-related object detection, themethod may include receiving an input image by an input of an objectdetector; and

detecting, by an object detector, objects that appear in the inputimage; wherein the detecting may include searching for (i) a firstobject having a first size that may be within a first size range andbelongs to a four wheel vehicle class, (ii) a second object having asecond size that may be within a second size range and belongs to asubclass out of multiple four wheel vehicle subclasses, (iii) apedestrian, and (iv) a two wheel vehicle; wherein a maximum of the firstsize range does not substantially exceed a minimum of the second sizerange.

The object detector may be trained to detect (i) four wheel vehiclehaving a size within the first size range and belongs to a four wheelvehicle class, and at least two out of (a) a car having a size withinthe second size range, (b) a truck having a size within the second sizerange, (c) a bus having a size within the second size range, and (d) avan having a size within the second size range.

The receiving may be preceded by training the object detector to detect(i) four wheel vehicle having a size within the first size range andbelongs to a four wheel vehicle class, and at least two out of (a) a carhaving a size within the second size range, (b) a truck having a sizewithin the second size range, (c) a bus having a size within the secondsize range, and (d) a van having a size within the second size range.

Each one of the four wheel vehicle class, at least some of the multiplefour wheel vehicle subclasses, may have a unique set of anchors.

Each one of the four wheel vehicle class, two wheel vehicle and thepedestrian may have a unique set of anchors.

The object detector may include a shallow neural network that may befollowed by a region unit.

The the region unit may include a dedicated section for each one out ofthe four wheel vehicle class, the two wheel vehicle and the pedestrian.

The the shallow neural network may include five by file convolutionalfilters.

The first size range and the second size range may not overlap.

The first size range and the second size range partially overlap.

There may be provided a non-transitory computer readable medium fordriving-related object detection by an object detector, thenon-transitory computer readable medium stores instructions forreceiving an input image by an input of the object detector; anddetecting, by an object detector, objects that appear in the inputimage; wherein the detecting may include searching for (i) a firstobject having a first size that may be within a first size range andbelongs to a four wheel vehicle class, (ii) a second object having asecond size that may be within a second size range and belongs to asubclass out of multiple four wheel vehicle subclasses, (iii) apedestrian, and (iv) a two wheel vehicle; wherein a maximum of the firstsize range does not substantially exceed a minimum of the second sizerange.

The object detector may be trained to detect (i) four wheel vehiclehaving a size within the first size range and belongs to a four wheelvehicle class, and at least two out of (a) a car having a size withinthe second size range, (b) a truck having a size within the second sizerange, (c) a bus having a size within the second size range, and (d) avan having a size within the second size range.

The non-transitory computer readable medium that stores instructions fortraining the object detector to detect (i) four wheel vehicle having asize within the first size range and belongs to a four wheel vehicleclass, and at least two out of (a) a car having a size within the secondsize range, (b) a truck having a size within the second size range, (c)a bus having a size within the second size range, and (d) a van having asize within the second size range.

Each one of the four wheel vehicle class, at least some of the multiplefour wheel vehicle subclasses, may have a unique set of anchors.

Each one of the four wheel vehicle class, two wheel vehicle and thepedestrian may have a unique set of anchors.

The object detector may include a shallow neural network that may befollowed by a region unit.

The non-transitory computer readable medium wherein the region unit mayinclude a dedicated section for each one out of the four wheel vehicleclass, the two wheel vehicle and the pedestrian.

The non-transitory computer readable medium wherein the shallow neuralnetwork may include five by file convolutional filters.

The first size range and the second size range may not overlap.

The first size range and the second size range partially overlap.

There may be provided an object detector that may include an input, ashallow neural network and a region unit; wherein the region unitfollows the shallow neural network; wherein the input may be configuredto receive an input image; and wherein the shallow neural network andthe region unit may be configured to cooperate and detect objects thatappear in the input image; wherein a detecting of the object may includemay include searching for (i) a first object having a first size thatmay be within a first size range and belongs to a four wheel vehicleclass, (ii) a second object having a second size that may be within asecond size range and belongs to a subclass out of multiple four wheelvehicle subclasses, (iii) a pedestrian, and (iv) a two wheel vehicle;wherein a maximum of the first size range does not substantially exceeda minimum of the second size range.

The object detector may be trained to detect (i) four wheel vehiclehaving a size within the first size range and belongs to a four wheelvehicle class, and at least two out of (a) a car having a size withinthe second size range, (b) a truck having a size within the second sizerange, (c) a bus having a size within the second size range, and (d) avan having a size within the second size range.

The receiving may be preceded by training the object detector to detect(i) four wheel vehicle having a size within the first size range andbelongs to a four wheel vehicle class, and at least two out of (a) a carhaving a size within the second size range, (b) a truck having a sizewithin the second size range, (c) a bus having a size within the secondsize range, and (d) a van having a size within the second size range.

Each one of the four wheel vehicle class, at least some of the multiplefour wheel vehicle subclasses, may have a unique set of anchors.

Each one of the four wheel vehicle class, two wheel vehicle and thepedestrian may have a unique set of anchors.

The region unit may include a dedicated section for each one out of thefour wheel vehicle class, the two wheel vehicle and the pedestrian.

The shallow neural network may include five by file convolutionalfilters.

The first size range and the second size range may not overlap.

The first size range and the second size range partially overlap.

BRIEF DESCRIPTION OF THE DRAWINGS

The embodiments of the disclosure will be understood and appreciatedmore fully from the following detailed description, taken in conjunctionwith the drawings in which:

FIG. 1 illustrates an example of a method for object detection;

FIG. 2 illustrates an example of an image;

FIG. 3 illustrates an example of a classification of some of the objectsthat appear in the image;

FIG. 4 illustrates an example of the image of FIG. 1 with bounding boxesthat surround some of the objects that appear in the image;

FIG. 5 illustrates an example of an object detector;

FIG. 6 illustrates an example of various objects; and

FIG. 7 illustrates an example of a training process.

DESCRIPTION OF EXAMPLE EMBODIMENTS

In the following detailed description, numerous specific details are setforth in order to provide a thorough understanding of the invention.However, it will be understood by those skilled in the art that thepresent invention may be practiced without these specific details. Inother instances, well-known methods, procedures, and components have notbeen described in detail so as not to obscure the present invention.

The subject matter regarded as the invention is particularly pointed outand distinctly claimed in the concluding portion of the specification.The invention, however, both as to organization and method of operation,together with objects, features, and advantages thereof, may best beunderstood by reference to the following detailed description when readwith the accompanying drawings.

It will be appreciated that for simplicity and clarity of illustration,elements shown in the figures have not necessarily been drawn to scale.For example, the dimensions of some of the elements may be exaggeratedrelative to other elements for clarity. Further, where consideredappropriate, reference numerals may be repeated among the figures toindicate corresponding or analogous elements.

Because the illustrated embodiments of the present invention may for themost part, be implemented using electronic components and circuits knownto those skilled in the art, details will not be explained in anygreater extent than that considered necessary as illustrated above, forthe understanding and appreciation of the underlying concepts of thepresent invention and in order not to obfuscate or distract from theteachings of the present invention.

Any reference in the specification to a method should be applied mutatismutandis to a device or system capable of executing the method and/or toa non-transitory computer readable medium that stores instructions forexecuting the method.

Any reference in the specification to a system or device should beapplied mutatis mutandis to a method that may be executed by the system,and/or may be applied mutatis mutandis to non-transitory computerreadable medium that stores instructions executable by the system.

Any reference in the specification to a non-transitory computer readablemedium should be applied mutatis mutandis to a device or system capableof executing instructions stored in the non-transitory computer readablemedium and/or may be applied mutatis mutandis to a method for executingthe instructions.

Any combination of any module or unit listed in any of the figures, anypart of the specification and/or any claims may be provided.

There may be provided a low power object detection system (detector),non-transitory computer readable medium, and method. The objectdetection system, non-transitory computer readable medium and method mayprevent errors in learning processes resulting of inaccurate tagging ofrelatively small four wheel vehicles by classifying (during the trainingprocess) objects that are relatively small (appear small in an inputimage)—within a first size range to a general class of four wheelvehicles.

Larger four wheel vehicle may be classified more accurately tosubclasses such as car, bur, truck, van and the like. Other classes(used for at least classifying small objects) include, for example twowheel vehicles and pedestrians.

Each of these other classes may also include subclasses that may beapplied to objects that are larger and can be accurately tagged (duringthe training process) to finer subclasses.

This size based classification increases the accuracy of the referenceinformation received during the training, improves the accuracy of thetraining process, improves the accuracy of the object detection and alsoprevents the training process to spend too much resources on attemptingto differentiate between insignificant differences. This also providesan object detector that is fine tunes to differentiate betweendifference that are significant.

After the completion of the training process the object detector it setto detect in an accurate manner the objects according to their size andclasses or subclasses.

FIG. 1 illustrates method 9270 for driving-related object detection.

Method 9270 may include the steps of:

-   -   Step 9272 of receiving an input image by an input of an object        detector.    -   Step 9274 of detecting, by an object detector, objects that        appear in the input image.

Step 9272 may include searching for (i) a first object having a firstsize that is within a first size range and belongs to a four wheelvehicle class, (ii) a second object having a second size that is withina second size range and belongs to a subclass out of multiple four wheelvehicle subclasses, (iii) a pedestrian, and (iv) a two wheel vehicle;wherein a maximum of the first size range does not substantially exceeda minimum of the second size range.

The object detector may be trained to perform said search (and method9270 may include the training—step 9271) by feeding the object detectorwith images of objects that are tagged according to the searched objects(i) till (iv). The object detector may be also trained to reject objectsthat are too big and. The training includes feeding the object detectorwith images that include objects of at least one of the four types(i)-(iv), generating reference information that tags the objectsaccording the the searched types, calculating an error between theoutcome of the object detector and the reference information and feedingthe error to the object detector.

The subclasses of the four wheel vehicle class may include at least someof the following car, truck, bus, van and the like. The subclasses mayinclude or may be further partitioned to certain type of vehicle, model,and the like.

Accordingly—the classification system may include two layers (singleclass and single layer of subclasses) or even more layer—to provide ahierarchical classification system that may include more than twolayers. For example—a first layer includes a four wheel vehicle, thesecond layer (subclasses) include car, bus, truck, van and the thirdlayer may include a manufacturer, yet a fourth layer may include model,and the like.

The class of pedestrians and/or the class of two wheel vehicles can alsoinclude subclasses to include two or more layers.

Each one of the four wheel vehicle class, at least some of the multiplefour wheel vehicle subclasses, may have has a unique set of anchors. Theunique sets of anchors may be selected based on the expected shape ofthe objects that belong to the class and/or the subclass.

Each one of the four wheel vehicle class, two wheel vehicle and thepedestrian has a unique set of anchors.

Anchors may be regarded as initial templates of bounding boxes and usingdifferent anchors to different classes may reduce the computationalresources, speed the detection and increase the accuracy of the boundingboxes when the different anchors are selected according to the expectedshapes of the different vehicles. For example, in a side view, a busappears longer and higher than a private car. Yet for another example apedestrian may require bounding boxes that have a height that exceedstheir width—while trucks (for example in side view) may require boundingboxes that have a height that is smaller than their width.

FIG. 2 is an example of an image 9301 that includes first bus 9311,second bus 9314, third bus 9316, first truck 9313, second truck 9317,third truck 9318, first car 9315, first bicycle 9319, and first footscooter 9312.

FIG. 3 illustrates the tagging of the objects of image 9301. The taggingmay be included in a reference information used to train the objectdetector or may be the outcome of the object detection process.

Third bus 9316, second truck 9317, third truck 9318, first car 9315 andfirst bicycle 9319 are too small (for example have a size within a firstsize range) and therefore are tagged to classes and not to subclasses.

Third bus 9316, second truck 9317, third truck 9318, first car 9315 areregarded as belonging to a four wheel vehicles class 9321.

The first bicycle 9319 is tagged to belonging to a two wheel vehicleclass 9322.

First bus 9311 is large enough (has a size within a second size range)to be tagged as a truck 9325. First bus 9311 and second bus 9314 arelarge enough (has a size within a second size range) to be tagged as abus. First foot scooter 9312 is large enough (has a size within a secondsize range) to be tagged as a foot scooter 9325.

FIG. 4 illustrates an example of a possible output of the objectdetector—bounding boxes 9310, 9311, 9312, 9313, 9314, 9315, 9316, 9317,9318 and 9319 that surround pedestrian 9310, first bus 9311, footscooter 9312, first truck 9313, second bus 9314, first car 9315, thirdbus 9316, second truck 9317, third truck 9318, first bicycle 9319,respectively.

Each bounding is represented by information 9025 that may includecoordinates (x,y,h,w) of the bounding boxes, objectiveness and class.The coordinate indicate the location (x,y) as well as the height andwidth of the bounding boxes. Objectiveness provides a confidence levelthat an object exists. Class—class of object—as illustrated above). The(x,y) coordinates may represent the center of the bounding box.

The object detection may be compliant to any flavor of YOLO—but otherobject detection schemes may be applied.

FIG. 5 illustrates an object detector 9000″ and FIG. 7 illustrates atraining process of the object detector.

Object detector 9000″ may include an input 9250, a shallow neuralnetwork 9252 and a region unit 9254.

The region unit 9254 follows the shallow neural network 9252.

Input 9250 may be configured to receive an input image 9001.

The shallow neural network 9252 and the region unit 9254 may beconfigured to cooperate (both participate in the object detectionprocess—the region unit processed the output of the shallow neuralnetwork) and detect objects that appear in the input image.

The detecting of the object may include may include searching for (i) afirst object having a first size that may be within a first size rangeand belongs to a four wheel vehicle class, (ii) a second object having asecond size that may be within a second size range and belongs to asubclass out of multiple four wheel vehicle subclasses, (iii) apedestrian, and (iv) a two wheel vehicle; wherein a maximum of the firstsize range does not substantially exceed a minimum of the second sizerange.

The shallow neural network 9252 may include convolutional and spoolinglayers.

The convolutional layers may include convolutional filters. Theconvolutional filters may be of any shape and size—for example be fiveby five convolutional filters (have a kernel of five by five elements),be a three by three convolutional filters (have a kernel of three bythree elements), and the like.

Object detector 9000″ may be configured to execute method 9270.

The region unit may include a dedicated section for each one out of thefour wheel vehicle class, the two wheel vehicle and the pedestrian. Thiswill improve the detection per each class of objects.

At least a part of the object detector may be a processing circuitrythat may be implemented as a central processing unit (CPU), and/or oneor more other integrated circuits such as application-specificintegrated circuits (ASICs), field programmable gate arrays (FPGAs),full-custom integrated circuits, etc., or a combination of suchintegrated circuits.

At least a part of the object detector may be application implemented inhardware, firmware, or software that may be executed by a processingcircuitry.

Regarding the training process:

Test images 9001 are fed to shallow neural network 9252 that outputs,for each test image, a shallow neural network output that may be atensor with multiple features per segment of the test image. The regionunit 9054 is configured to receive the output from shallow neuralnetwork 9252 and calculate and output candidate bounding boxes per testimage. Actual results such as the output candidate bounding boxes pertest image may be fed to error calculation unit 9050.

Error calculation unit 9050 also receives desired results 9045—objectsthat are tagged to belong to (i) a four wheel vehicle class (if the sizewith within the first size range), or to (ii) a subclass out of multiplefour wheel vehicle subclasses ((if the size with within the first sizerange), (iii) a pedestrian, and (iv) a two wheel vehicle.

Error calculation unit 9050 calculates an error 9055 between the theactual results and the desired results- and the error is fed to theshallow neural network 9252 during the training process.

It should be noted that in addition to the mentioned above training—theshallow neural network 9252 may be trained to reject (not detect)objects that are too big—for example outside the first and second sizeranges.

This may require to train the shallow neural network 9252 not to detectsaid objects.

FIG. 7 illustrates various objects such as 9031, 9032, 9033 and 9034.

Objects 9033 and 9034 are too big and should be ignored of.

While the foregoing written description of the invention enables one ofordinary skill to make and use what is considered presently to be thebest mode thereof, those of ordinary skill will understand andappreciate the existence of variations, combinations, and equivalents ofthe specific embodiment, method, and examples herein. The inventionshould therefore not be limited by the above described embodiment,method, and examples, but by all embodiments and methods within thescope and spirit of the invention as claimed.

In the foregoing specification, the invention has been described withreference to specific examples of embodiments of the invention. It will,however, be evident that various modifications and changes may be madetherein without departing from the broader spirit and scope of theinvention as set forth in the appended claims.

Moreover, the terms “front,” “back,” “top,” “bottom,” “over,” “under”and the like in the description and in the claims, if any, are used fordescriptive purposes and not necessarily for describing permanentrelative positions. It is understood that the terms so used areinterchangeable under appropriate circumstances such that theembodiments of the invention described herein are, for example, capableof operation in other orientations than those illustrated or otherwisedescribed herein.

Furthermore, the terms “assert” or “set” and “negate” (or “deassert” or“clear”) are used herein when referring to the rendering of a signal,status bit, or similar apparatus into its logically true or logicallyfalse state, respectively. If the logically true state is a logic levelone, the logically false state is a logic level zero. And if thelogically true state is a logic level zero, the logically false state isa logic level one.

Those skilled in the art will recognize that the boundaries betweenlogic blocks are merely illustrative and that alternative embodimentsmay merge logic blocks or circuit elements or impose an alternatedecomposition of functionality upon various logic blocks or circuitelements. Thus, it is to be understood that the architectures depictedherein are merely exemplary, and that in fact many other architecturesmay be implemented which achieve the same functionality.

Any arrangement of components to achieve the same functionality iseffectively “associated” such that the desired functionality isachieved. Hence, any two components herein combined to achieve aparticular functionality may be seen as “associated with” each othersuch that the desired functionality is achieved, irrespective ofarchitectures or intermedial components. Likewise, any two components soassociated can also be viewed as being “operably connected,” or“operably coupled,” to each other to achieve the desired functionality.

Furthermore, those skilled in the art will recognize that boundariesbetween the above described operations merely illustrative. The multipleoperations may be combined into a single operation, a single operationmay be distributed in additional operations and operations may beexecuted at least partially overlapping in time. Moreover, alternativeembodiments may include multiple instances of a particular operation,and the order of operations may be altered in various other embodiments.

Also for example, in one embodiment, the illustrated examples may beimplemented as circuitry located on a single integrated circuit orwithin a same device. Alternatively, the examples may be implemented asany number of separate integrated circuits or separate devicesinterconnected with each other in a suitable manner.

However, other modifications, variations and alternatives are alsopossible. The specifications and drawings are, accordingly, to beregarded in an illustrative rather than in a restrictive sense.

In the claims, any reference signs placed between parentheses shall notbe construed as limiting the claim. The word ‘comprising’ does notexclude the presence of other elements or steps then those listed in aclaim. Furthermore, the terms “a” or “an,” as used herein, are definedas one or more than one. Also, the use of introductory phrases such as“at least one” and “one or more” in the claims should not be construedto imply that the introduction of another claim element by theindefinite articles “a” or “an” limits any particular claim containingsuch introduced claim element to inventions containing only one suchelement, even when the same claim includes the introductory phrases “oneor more” or “at least one” and indefinite articles such as “a” or “an.”The same holds true for the use of definite articles. Unless statedotherwise, terms such as “first” and “second” are used to arbitrarilydistinguish between the elements such terms describe. Thus, these termsare not necessarily intended to indicate temporal or otherprioritization of such elements. The mere fact that certain measures arerecited in mutually different claims does not indicate that acombination of these measures cannot be used to advantage.

While certain features of the invention have been illustrated anddescribed herein, many modifications, substitutions, changes, andequivalents will now occur to those of ordinary skill in the art. It is,therefore, to be understood that the appended claims are intended tocover all such modifications and changes as fall within the true spiritof the invention.

It is appreciated that various features of the embodiments of thedisclosure which are, for clarity, described in the contexts of separateembodiments may also be provided in combination in a single embodiment.Conversely, various features of the embodiments of the disclosure whichare, for brevity, described in the context of a single embodiment mayalso be provided separately or in any suitable sub-combination.

It will be appreciated by persons skilled in the art that theembodiments of the disclosure are not limited by what has beenparticularly shown and described hereinabove. Rather the scope of theembodiments of the disclosure is defined by the appended claims andequivalents thereof.

What is claimed is:
 1. A method for driving-related object detection,the method comprises: receiving an input image by an input of an objectdetector; and detecting, by an object detector, objects that appear inthe input image; wherein the detecting comprises searching for (i) afirst object having a first size that is within a first size range andbelongs to a four wheel vehicle class, (ii) a second object having asecond size that is within a second size range and belongs to a subclassout of multiple four wheel vehicle subclasses, (iii) a pedestrian, and(iv) a two wheel vehicle; wherein a maximum of the first size range doesnot substantially exceed a minimum of the second size range.
 2. Themethod according to claim 1 wherein the object detector is trained todetect (i) four wheel vehicle having a size within the first size rangeand belongs to a four wheel vehicle class, and at least two out of (a) acar having a size within the second size range, (b) a truck having asize within the second size range, (c) a bus having a size within thesecond size range, and (d) a van having a size within the second sizerange.
 3. The method according to claim 1 wherein the receiving ispreceded by training the object detector to detect (i) four wheelvehicle having a size within the first size range and belongs to a fourwheel vehicle class, and at least two out of (a) a car having a sizewithin the second size range, (b) a truck having a size within thesecond size range, (c) a bus having a size within the second size range,and (d) a van having a size within the second size range.
 4. The methodaccording to claim 1 wherein each one of the four wheel vehicle class,at least some of the multiple four wheel vehicle subclasses, has aunique set of anchors.
 5. The method according to claim 1 wherein eachone of the four wheel vehicle class, two wheel vehicle and thepedestrian has a unique set of anchors.
 6. The method according to claim1 wherein the object detector comprises a shallow neural network that isfollowed by a region unit.
 7. The method according to claim 6 whereinthe region unit comprises a dedicated section for each one out of thefour wheel vehicle class, the two wheel vehicle and the pedestrian. 8.The method according to claim 6 wherein the shallow neural networkcomprises five by file convolutional filters.
 9. The method according toclaim 1 wherein the first size range and the second size range do notoverlap.
 10. The method according to claim 1 wherein the first sizerange and the second size range partially overlap.
 11. A non-transitorycomputer readable medium for driving-related object detection by anobject detector, the non-transitory computer readable medium storesinstructions for: receiving an input image by an input of the objectdetector; and detecting, by an object detector, objects that appear inthe input image; wherein the detecting comprises searching for (i) afirst object having a first size that is within a first size range andbelongs to a four wheel vehicle class, (ii) a second object having asecond size that is within a second size range and belongs to a subclassout of multiple four wheel vehicle subclasses, (iii) a pedestrian, and(iv) a two wheel vehicle; wherein a maximum of the first size range doesnot substantially exceed a minimum of the second size range.
 12. Thenon-transitory computer readable medium according to claim 11 whereinthe object detector is trained to detect (i) four wheel vehicle having asize within the first size range and belongs to a four wheel vehicleclass, and at least two out of (a) a car having a size within the secondsize range, (b) a truck having a size within the second size range, (c)a bus having a size within the second size range, and (d) a van having asize within the second size range.
 13. The non-transitory computerreadable medium according to claim 11 that stores instructions fortraining the object detector to detect (i) four wheel vehicle having asize within the first size range and belongs to a four wheel vehicleclass, and at least two out of (a) a car having a size within the secondsize range, (b) a truck having a size within the second size range, (c)a bus having a size within the second size range, and (d) a van having asize within the second size range.
 14. The non-transitory computerreadable medium according to claim 11 wherein each one of the four wheelvehicle class, at least some of the multiple four wheel vehiclesubclasses, has a unique set of anchors.
 15. The non-transitory computerreadable medium according to claim 11 wherein each one of the four wheelvehicle class, two wheel vehicle and the pedestrian has a unique set ofanchors.
 16. The non-transitory computer readable medium according toclaim 11 wherein the object detector comprises a shallow neural networkthat is followed by a region unit.
 17. The non-transitory computerreadable medium according to claim 16 wherein the region unit comprisesa dedicated section for each one out of the four wheel vehicle class,the two wheel vehicle and the pedestrian.
 18. The non-transitorycomputer readable medium according to claim 16 wherein the shallowneural network comprises five by file convolutional filters.
 19. Thenon-transitory computer readable medium according to claim 11 whereinthe first size range and the second size range do not overlap.
 20. Thenon-transitory computer readable medium according to claim 11 whereinthe first size range and the second size range partially overlap.
 21. Anobject detector that comprises an input, a shallow neural network and aregion unit; wherein the region unit follows the shallow neural network;wherein the input is configured to receive an input image; and whereinthe shallow neural network and the region unit are configured tocooperate and detect objects that appear in the input image; wherein adetecting of the object comprises comprises searching for (i) a firstobject having a first size that is within a first size range and belongsto a four wheel vehicle class, (ii) a second object having a second sizethat is within a second size range and belongs to a subclass out ofmultiple four wheel vehicle subclasses, (iii) a pedestrian, and (iv) atwo wheel vehicle; wherein a maximum of the first size range does notsubstantially exceed a minimum of the second size range.
 22. The objectdetector according to claim 11 wherein the object detector is trained todetect (i) four wheel vehicle having a size within the first size rangeand belongs to a four wheel vehicle class, and at least two out of (a) acar having a size within the second size range, (b) a truck having asize within the second size range, (c) a bus having a size within thesecond size range, and (d) a van having a size within the second sizerange.
 23. The object detector according to claim 11 wherein thereceiving is preceded by training the object detector to detect (i) fourwheel vehicle having a size within the first size range and belongs to afour wheel vehicle class, and at least two out of (a) a car having asize within the second size range, (b) a truck having a size within thesecond size range, (c) a bus having a size within the second size range,and (d) a van having a size within the second size range.
 24. The objectdetector according to claim 11 wherein each one of the four wheelvehicle class, at least some of the multiple four wheel vehiclesubclasses, has a unique set of anchors.
 25. The object detectoraccording to claim 11 wherein each one of the four wheel vehicle class,two wheel vehicle and the pedestrian has a unique set of anchors. 26.The object detector according to claim 11 wherein the region unitcomprises a dedicated section for each one out of the four wheel vehicleclass, the two wheel vehicle and the pedestrian.
 27. The object detectoraccording to claim 11 wherein the shallow neural network comprises fiveby file convolutional filters.
 28. The object detector according toclaim 11 wherein the first size range and the second size range do notoverlap.
 29. The object detector according to claim 11 wherein the firstsize range and the second size range partially overlap.